package com.whu.waterworks.model;
// default package

import java.math.BigDecimal;
import javax.persistence.AttributeOverride;
import javax.persistence.AttributeOverrides;
import javax.persistence.Column;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * TAlertRecord entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "T_ALERT_RECORD", schema = "ZJ")
public class AlertRecord implements java.io.Serializable {

	// Fields

	private AlertRecordId id;
	private String alertType;
	private String username;
	private String disposealertname;
	private String stationnum;
	private String flag;
	private String value;
	private String uppervalue;
	private String lowervalue;
	private String time;

	// Constructors

	/** default constructor */
	public AlertRecord() {
	}

	/** minimal constructor */
	public AlertRecord(AlertRecordId id) {
		this.id = id;
	}

	/** full constructor */
	public AlertRecord(AlertRecordId id, String alertType, String username,
			String disposealertname, String stationnum, String flag) {
		this.id = id;
		this.alertType = alertType;
		this.username = username;
		this.disposealertname = disposealertname;
		this.stationnum = stationnum;
		this.flag = flag;
	}

	// Property accessors
	@EmbeddedId
	@AttributeOverrides({
			@AttributeOverride(name = "alertId", column = @Column(name = "ALERT_ID", nullable = false, precision = 22, scale = 0)),
			@AttributeOverride(name = "time", column = @Column(name = "TIME", nullable = false, length = 50)) })
	public AlertRecordId getId() {
		return this.id;
	}

	public void setId(AlertRecordId id) {
		this.id = id;
	}

	@Column(name = "ALERT_TYPE")
	public String getAlertType() {
		return this.alertType;
	}

	public void setAlertType(String alertType) {
		this.alertType = alertType;
	}

	@Column(name = "USERNAME")
	public String getUsername() {
		return this.username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	@Column(name = "DISPOSEALERTNAME")
	public String getDisposealertname() {
		return this.disposealertname;
	}

	public void setDisposealertname(String disposealertname) {
		this.disposealertname = disposealertname;
	}

	@Column(name = "STATIONNUM")
	public String getStationnum() {
		return this.stationnum;
	}

	public void setStationnum(String stationnum) {
		this.stationnum = stationnum;
	}

	@Column(name = "FLAG", precision = 22, scale = 0)
	public String getFlag() {
		return this.flag;
	}

	public void setFlag(String flag) {
		this.flag = flag;
	}

	@Column(name = "VALUE")
	public String getValue() {
		return value;
	}

	public void setValue(String value) {
		this.value = value;
	}

	@Column(name = "UPPERVALUE")
	public String getUppervalue() {
		return uppervalue;
	}

	public void setUppervalue(String uppervalue) {
		this.uppervalue = uppervalue;
	}

	@Column(name = "LOWERVALUE")
	public String getLowervalue() {
		return lowervalue;
	}

	public void setLowervalue(String lowervalue) {
		this.lowervalue = lowervalue;
	}

	@Column(name = "TIME",insertable=false,updatable=false)
	public String getTime() {
		return time;
	}

	public void setTime(String time) {
		this.time = time;
	}

}